/*
 *  InterFaceCalendario.java
 *
 * Created on 04/03/2011, 12:29:18
 *
 */

package calendario;

import java.awt.Color;
import java.util.ArrayList;
import java.util.Calendar;
import java.util.List;
import javax.swing.JLabel;
import org.hibernate.Session;
import pbf.conf.hibernate.HibernateUtil;
import pbf.conf.hibernate.entidades.Calendario;

/**
 *
 * @author Ricardo Tavares
 */
public class InterFaceCalendario extends javax.swing.JDialog
{
    private final Color DIA_SELECIONADO =  new Color(68, 197, 243);
    private final Color DIA_PADRAO = new Color(255,255,255);
    private final int DEZ=11, JAN=0;
    private ArrayList<JLabel> listaLabel = new ArrayList<JLabel>();
    private JLabel labelAtivo = null, labelSelecionado = null;
    private int mes,ano;
    private String data;

    public InterFaceCalendario(java.awt.Frame parent, boolean modal)
    {
        super(parent, modal);
        initComponents();

        // Pega o mês e Ano atual
        Calendar hora = Calendar.getInstance();     // Instância Objeto
        mes = hora.get(Calendar.MONTH);             // Pega o Mês
        ano = hora.get(Calendar.YEAR);                 //  Pega o Ano

        // Disponibiliza informação no Viso Ex: Junho de 2011
        rotulo.setText(getStringMes(mes)+" de "+ano);

        // Monta a Data
        data = hora.get(Calendar.DAY_OF_MONTH)+"/"+(mes+1)+"/"+ano;

        // Monta o ArrayList com os JLabel
        setListaLabel();

        // Adiciona Eventos ao JLabel
        addEvent();

        // Limpa o JLabel, dest forma limpando o Calendario
        removerAllGrade();

        // Monta o Calendario Adicionando o dias nas posições relativas
        setCalendario();

        // Foi inserido essa linha para evita erros
        labelSelecionado = l1;
    }

    private void setCalendario()
    {

        Session sessao = HibernateUtil.openSession();
        sessao.beginTransaction();

        // Consulta o Banco para extrair informação de um determinado mês e ano, retornando a informação daquele mês.
        List <Calendario> lista = (List<Calendario>) sessao.createQuery("From Calendario where CALENDARIO_ANO="+ano+" AND CALENDARIO_MES="+(mes+1)).list();

        for(Calendario c : lista)
        {
            // Adicionar o dia na posição exarta que deveria ser inserida
            listaLabel.get((c.getCalendarioPosicao()-1)).setText(""+c.getCalendarioDia());
            
            // Habilita o JLabel para o usuario pode Seleciona-lo
            listaLabel.get((c.getCalendarioPosicao()-1)).setVisible(true);

            //System.out.println(c.getCalendarioDia()+"/"+c.getCalendarioMes()+"/"+c.getCalendarioAno()+" Posição: "+c.getCalendarioPosicao());
        }
        
        sessao.getTransaction().commit();
        sessao.close();
    }

    private void addEvent()
    {
        for(int i = 0; i <=36; i++)
        {
            listaLabel.get(i).addMouseListener(new java.awt.event.MouseAdapter()
            {
                public void mouseClicked(java.awt.event.MouseEvent evt) 
                {
                    // Recebe o Objeto JLabel
                    labelAtivo = (JLabel) evt.getSource();
                    
                    // Define uma cor de fundo
                    labelAtivo.setBackground(DIA_SELECIONADO);
                    
                    // Monta a String com a data atual
                    data = labelAtivo.getText()+"/"+(mes+1)+"/"+ano;

                    // Faz que o JLabel selecionado anteriormente possa volta a cor original.
                    if(labelSelecionado != null)
                        labelSelecionado.setBackground(DIA_PADRAO);

                    // Atribui que o JLabel Selecionado é aquele que esta ativo e que acabou de ser Clicado
                    labelSelecionado = labelAtivo;
                }
                public void mouseEntered(java.awt.event.MouseEvent evt) 
                {   // Atribui uma borda
                    labelAtivo = (JLabel) evt.getSource();
                    labelAtivo.setBorder(javax.swing.BorderFactory.createEtchedBorder());
                }
                public void mouseExited(java.awt.event.MouseEvent evt)
                {   // Remove a borda
                    labelAtivo = (JLabel) evt.getSource();
                    labelAtivo.setBorder(null);
                }
            });
        }
    }

    private void setListaLabel()
    {
        listaLabel.add(l1);
        listaLabel.add(l2);
        listaLabel.add(l3);
        listaLabel.add(l4);
        listaLabel.add(l5);
        listaLabel.add(l6);
        listaLabel.add(l7);
        listaLabel.add(l8);
        listaLabel.add(l9);
        listaLabel.add(l10);
        listaLabel.add(l11);
        listaLabel.add(l12);
        listaLabel.add(l13);
        listaLabel.add(l14);
        listaLabel.add(l15);
        listaLabel.add(l16);
        listaLabel.add(l17);
        listaLabel.add(l18);
        listaLabel.add(l19);
        listaLabel.add(l20);
        listaLabel.add(l21);
        listaLabel.add(l22);
        listaLabel.add(l23);
        listaLabel.add(l24);
        listaLabel.add(l25);
        listaLabel.add(l26);
        listaLabel.add(l27);
        listaLabel.add(l28);
        listaLabel.add(l29);
        listaLabel.add(l30);
        listaLabel.add(l31);
        listaLabel.add(l32);
        listaLabel.add(l33);
        listaLabel.add(l34);
        listaLabel.add(l35);
        listaLabel.add(l36);
        listaLabel.add(l37);
    }

    public String getData()
    {
        return data;
    }

    private void removerAllGrade()
    {
        for(JLabel l: listaLabel)
        {
            l.setText("");
            l.setVisible(false);
        }
    }

    private void updateGrade()
    {
            // Remove a Seleção do dia
            labelSelecionado.setBackground(DIA_PADRAO);

            // Mostra o mês e ano relacionado
            rotulo.setText(getStringMes(mes)+" de "+ano);

            // Limpa calendario
            removerAllGrade();

            // Monta o calendario
            setCalendario();
    }

    private void proximaGrade()
    {
            mes++;

            if(mes > DEZ)
            {
                mes = JAN;
                ano++;
            }

            updateGrade();
    }

    private void anteriorGrade()
    {
            mes--;

            if(mes < JAN)
            {
                mes = DEZ;
                ano--;
            }

            updateGrade();
    }

    private String getStringMes(int mes)
    {
        switch(mes)
        {
            case 0: return "Janeiro";
            case 1: return "Fevereiro";
            case 2: return "Março";
            case 3: return "Abril";
            case 4: return "Maio";
            case 5: return "Junho";
            case 6: return "Julho";
            case 7: return  "Agosto";
            case 8: return "Setembro";
            case 9: return "Outubro";
            case 10: return "Novembro";
            default: return "Dezembro";
        }
    }

    @SuppressWarnings("unchecked")
    // <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents
    private void initComponents() {

        jLabel1 = new javax.swing.JLabel();
        l2 = new javax.swing.JLabel();
        l1 = new javax.swing.JLabel();
        l3 = new javax.swing.JLabel();
        l4 = new javax.swing.JLabel();
        l5 = new javax.swing.JLabel();
        l6 = new javax.swing.JLabel();
        l7 = new javax.swing.JLabel();
        l8 = new javax.swing.JLabel();
        l9 = new javax.swing.JLabel();
        l10 = new javax.swing.JLabel();
        l11 = new javax.swing.JLabel();
        l12 = new javax.swing.JLabel();
        l13 = new javax.swing.JLabel();
        l14 = new javax.swing.JLabel();
        l21 = new javax.swing.JLabel();
        l20 = new javax.swing.JLabel();
        l19 = new javax.swing.JLabel();
        l18 = new javax.swing.JLabel();
        l17 = new javax.swing.JLabel();
        l16 = new javax.swing.JLabel();
        l15 = new javax.swing.JLabel();
        l22 = new javax.swing.JLabel();
        l23 = new javax.swing.JLabel();
        l24 = new javax.swing.JLabel();
        l25 = new javax.swing.JLabel();
        l26 = new javax.swing.JLabel();
        l27 = new javax.swing.JLabel();
        l28 = new javax.swing.JLabel();
        l29 = new javax.swing.JLabel();
        l30 = new javax.swing.JLabel();
        l31 = new javax.swing.JLabel();
        l32 = new javax.swing.JLabel();
        l33 = new javax.swing.JLabel();
        l34 = new javax.swing.JLabel();
        l35 = new javax.swing.JLabel();
        jLabel37 = new javax.swing.JLabel();
        jLabel38 = new javax.swing.JLabel();
        jLabel39 = new javax.swing.JLabel();
        jLabel40 = new javax.swing.JLabel();
        jLabel41 = new javax.swing.JLabel();
        jLabel42 = new javax.swing.JLabel();
        jSeparator1 = new javax.swing.JSeparator();
        rotulo = new javax.swing.JLabel();
        l36 = new javax.swing.JLabel();
        l37 = new javax.swing.JLabel();
        avancar = new javax.swing.JLabel();
        voltar = new javax.swing.JLabel();
        fundoLabel = new javax.swing.JLabel();
        fundoLabel.setBackground(Color.WHITE);

        setDefaultCloseOperation(javax.swing.WindowConstants.DISPOSE_ON_CLOSE);
        setTitle("Calendário v.1");
        setResizable(false);
        getContentPane().setLayout(null);

        jLabel1.setFont(new java.awt.Font("Tahoma", 1, 14));
        jLabel1.setHorizontalAlignment(javax.swing.SwingConstants.CENTER);
        jLabel1.setText("S");
        jLabel1.setHorizontalTextPosition(javax.swing.SwingConstants.CENTER);
        getContentPane().add(jLabel1);
        jLabel1.setBounds(210, 50, 30, 20);

        l2.setBackground(new java.awt.Color(255, 255, 255));
        l2.setHorizontalAlignment(javax.swing.SwingConstants.CENTER);
        l2.setText("2");
        l2.setHorizontalTextPosition(javax.swing.SwingConstants.CENTER);
        l2.setOpaque(true);
        getContentPane().add(l2);
        l2.setBounds(60, 80, 30, 30);

        l1.setBackground(new java.awt.Color(255, 255, 255));
        l1.setForeground(new java.awt.Color(255, 0, 0));
        l1.setHorizontalAlignment(javax.swing.SwingConstants.CENTER);
        l1.setText("1");
        l1.setHorizontalTextPosition(javax.swing.SwingConstants.CENTER);
        l1.setOpaque(true);
        getContentPane().add(l1);
        l1.setBounds(30, 80, 30, 30);

        l3.setBackground(new java.awt.Color(255, 255, 255));
        l3.setHorizontalAlignment(javax.swing.SwingConstants.CENTER);
        l3.setText("3");
        l3.setHorizontalTextPosition(javax.swing.SwingConstants.CENTER);
        l3.setOpaque(true);
        l3.addMouseListener(new java.awt.event.MouseAdapter() {
            public void mouseEntered(java.awt.event.MouseEvent evt) {
                l3MouseEntered(evt);
            }
            public void mouseExited(java.awt.event.MouseEvent evt) {
                l3MouseExited(evt);
            }
        });
        getContentPane().add(l3);
        l3.setBounds(90, 80, 30, 30);

        l4.setBackground(new java.awt.Color(255, 255, 255));
        l4.setHorizontalAlignment(javax.swing.SwingConstants.CENTER);
        l4.setText("4");
        l4.setHorizontalTextPosition(javax.swing.SwingConstants.CENTER);
        l4.setOpaque(true);
        getContentPane().add(l4);
        l4.setBounds(120, 80, 30, 30);

        l5.setBackground(new java.awt.Color(255, 255, 255));
        l5.setHorizontalAlignment(javax.swing.SwingConstants.CENTER);
        l5.setText("5");
        l5.setHorizontalTextPosition(javax.swing.SwingConstants.CENTER);
        l5.setOpaque(true);
        getContentPane().add(l5);
        l5.setBounds(150, 80, 30, 30);

        l6.setBackground(new java.awt.Color(255, 255, 255));
        l6.setHorizontalAlignment(javax.swing.SwingConstants.CENTER);
        l6.setText("6");
        l6.setHorizontalTextPosition(javax.swing.SwingConstants.CENTER);
        l6.setOpaque(true);
        l6.addMouseListener(new java.awt.event.MouseAdapter() {
            public void mouseEntered(java.awt.event.MouseEvent evt) {
                l6MouseEntered(evt);
            }
            public void mouseExited(java.awt.event.MouseEvent evt) {
                l6MouseExited(evt);
            }
        });
        getContentPane().add(l6);
        l6.setBounds(180, 80, 30, 30);

        l7.setBackground(new java.awt.Color(255, 255, 255));
        l7.setHorizontalAlignment(javax.swing.SwingConstants.CENTER);
        l7.setText("7");
        l7.setHorizontalTextPosition(javax.swing.SwingConstants.CENTER);
        l7.setOpaque(true);
        l7.addMouseListener(new java.awt.event.MouseAdapter() {
            public void mouseEntered(java.awt.event.MouseEvent evt) {
                l7MouseEntered(evt);
            }
            public void mouseExited(java.awt.event.MouseEvent evt) {
                l7MouseExited(evt);
            }
        });
        getContentPane().add(l7);
        l7.setBounds(210, 80, 30, 30);

        l8.setBackground(new java.awt.Color(255, 255, 255));
        l8.setForeground(new java.awt.Color(255, 0, 0));
        l8.setHorizontalAlignment(javax.swing.SwingConstants.CENTER);
        l8.setText("8");
        l8.setHorizontalTextPosition(javax.swing.SwingConstants.CENTER);
        l8.setOpaque(true);
        l8.addMouseListener(new java.awt.event.MouseAdapter() {
            public void mouseEntered(java.awt.event.MouseEvent evt) {
                l8MouseEntered(evt);
            }
            public void mouseExited(java.awt.event.MouseEvent evt) {
                l8MouseExited(evt);
            }
        });
        getContentPane().add(l8);
        l8.setBounds(30, 110, 30, 30);

        l9.setBackground(new java.awt.Color(255, 255, 255));
        l9.setHorizontalAlignment(javax.swing.SwingConstants.CENTER);
        l9.setText("9");
        l9.setHorizontalTextPosition(javax.swing.SwingConstants.CENTER);
        l9.setOpaque(true);
        l9.addMouseListener(new java.awt.event.MouseAdapter() {
            public void mouseEntered(java.awt.event.MouseEvent evt) {
                l9MouseEntered(evt);
            }
            public void mouseExited(java.awt.event.MouseEvent evt) {
                l9MouseExited(evt);
            }
        });
        getContentPane().add(l9);
        l9.setBounds(60, 110, 30, 30);

        l10.setBackground(new java.awt.Color(255, 255, 255));
        l10.setHorizontalAlignment(javax.swing.SwingConstants.CENTER);
        l10.setText("10");
        l10.setHorizontalTextPosition(javax.swing.SwingConstants.CENTER);
        l10.setOpaque(true);
        l10.addMouseListener(new java.awt.event.MouseAdapter() {
            public void mouseEntered(java.awt.event.MouseEvent evt) {
                l10MouseEntered(evt);
            }
            public void mouseExited(java.awt.event.MouseEvent evt) {
                l10MouseExited(evt);
            }
        });
        getContentPane().add(l10);
        l10.setBounds(90, 110, 30, 30);

        l11.setBackground(new java.awt.Color(255, 255, 255));
        l11.setHorizontalAlignment(javax.swing.SwingConstants.CENTER);
        l11.setText("11");
        l11.setHorizontalTextPosition(javax.swing.SwingConstants.CENTER);
        l11.setOpaque(true);
        l11.addMouseListener(new java.awt.event.MouseAdapter() {
            public void mouseEntered(java.awt.event.MouseEvent evt) {
                l11MouseEntered(evt);
            }
            public void mouseExited(java.awt.event.MouseEvent evt) {
                l11MouseExited(evt);
            }
        });
        getContentPane().add(l11);
        l11.setBounds(120, 110, 30, 30);

        l12.setBackground(new java.awt.Color(255, 255, 255));
        l12.setHorizontalAlignment(javax.swing.SwingConstants.CENTER);
        l12.setText("12");
        l12.setHorizontalTextPosition(javax.swing.SwingConstants.CENTER);
        l12.setOpaque(true);
        l12.addMouseListener(new java.awt.event.MouseAdapter() {
            public void mouseEntered(java.awt.event.MouseEvent evt) {
                l12MouseEntered(evt);
            }
            public void mouseExited(java.awt.event.MouseEvent evt) {
                l12MouseExited(evt);
            }
        });
        getContentPane().add(l12);
        l12.setBounds(150, 110, 30, 30);

        l13.setBackground(new java.awt.Color(255, 255, 255));
        l13.setHorizontalAlignment(javax.swing.SwingConstants.CENTER);
        l13.setText("13");
        l13.setHorizontalTextPosition(javax.swing.SwingConstants.CENTER);
        l13.setOpaque(true);
        l13.addMouseListener(new java.awt.event.MouseAdapter() {
            public void mouseEntered(java.awt.event.MouseEvent evt) {
                l13MouseEntered(evt);
            }
            public void mouseExited(java.awt.event.MouseEvent evt) {
                l13MouseExited(evt);
            }
        });
        getContentPane().add(l13);
        l13.setBounds(180, 110, 30, 30);

        l14.setBackground(new java.awt.Color(255, 255, 255));
        l14.setHorizontalAlignment(javax.swing.SwingConstants.CENTER);
        l14.setText("14");
        l14.setHorizontalTextPosition(javax.swing.SwingConstants.CENTER);
        l14.setOpaque(true);
        l14.addMouseListener(new java.awt.event.MouseAdapter() {
            public void mouseEntered(java.awt.event.MouseEvent evt) {
                l14MouseEntered(evt);
            }
            public void mouseExited(java.awt.event.MouseEvent evt) {
                l14MouseExited(evt);
            }
        });
        getContentPane().add(l14);
        l14.setBounds(210, 110, 30, 30);

        l21.setBackground(new java.awt.Color(255, 255, 255));
        l21.setHorizontalAlignment(javax.swing.SwingConstants.CENTER);
        l21.setText("21");
        l21.setHorizontalTextPosition(javax.swing.SwingConstants.CENTER);
        l21.setOpaque(true);
        l21.addMouseListener(new java.awt.event.MouseAdapter() {
            public void mouseEntered(java.awt.event.MouseEvent evt) {
                l21MouseEntered(evt);
            }
            public void mouseExited(java.awt.event.MouseEvent evt) {
                l21MouseExited(evt);
            }
        });
        getContentPane().add(l21);
        l21.setBounds(210, 140, 30, 30);

        l20.setBackground(new java.awt.Color(255, 255, 255));
        l20.setHorizontalAlignment(javax.swing.SwingConstants.CENTER);
        l20.setText("20");
        l20.setHorizontalTextPosition(javax.swing.SwingConstants.CENTER);
        l20.setOpaque(true);
        l20.addMouseListener(new java.awt.event.MouseAdapter() {
            public void mouseEntered(java.awt.event.MouseEvent evt) {
                l20MouseEntered(evt);
            }
            public void mouseExited(java.awt.event.MouseEvent evt) {
                l20MouseExited(evt);
            }
        });
        getContentPane().add(l20);
        l20.setBounds(180, 140, 30, 30);

        l19.setBackground(new java.awt.Color(255, 255, 255));
        l19.setHorizontalAlignment(javax.swing.SwingConstants.CENTER);
        l19.setText("19");
        l19.setHorizontalTextPosition(javax.swing.SwingConstants.CENTER);
        l19.setOpaque(true);
        l19.addMouseListener(new java.awt.event.MouseAdapter() {
            public void mouseEntered(java.awt.event.MouseEvent evt) {
                l19MouseEntered(evt);
            }
            public void mouseExited(java.awt.event.MouseEvent evt) {
                l19MouseExited(evt);
            }
        });
        getContentPane().add(l19);
        l19.setBounds(150, 140, 30, 30);

        l18.setBackground(new java.awt.Color(255, 255, 255));
        l18.setHorizontalAlignment(javax.swing.SwingConstants.CENTER);
        l18.setText("18");
        l18.setHorizontalTextPosition(javax.swing.SwingConstants.CENTER);
        l18.setOpaque(true);
        l18.addMouseListener(new java.awt.event.MouseAdapter() {
            public void mouseEntered(java.awt.event.MouseEvent evt) {
                l18MouseEntered(evt);
            }
            public void mouseExited(java.awt.event.MouseEvent evt) {
                l18MouseExited(evt);
            }
        });
        getContentPane().add(l18);
        l18.setBounds(120, 140, 30, 30);

        l17.setBackground(new java.awt.Color(255, 255, 255));
        l17.setHorizontalAlignment(javax.swing.SwingConstants.CENTER);
        l17.setText("17");
        l17.setHorizontalTextPosition(javax.swing.SwingConstants.CENTER);
        l17.setOpaque(true);
        l17.addMouseListener(new java.awt.event.MouseAdapter() {
            public void mouseEntered(java.awt.event.MouseEvent evt) {
                l17MouseEntered(evt);
            }
            public void mouseExited(java.awt.event.MouseEvent evt) {
                l17MouseExited(evt);
            }
        });
        getContentPane().add(l17);
        l17.setBounds(90, 140, 30, 30);

        l16.setBackground(new java.awt.Color(255, 255, 255));
        l16.setHorizontalAlignment(javax.swing.SwingConstants.CENTER);
        l16.setText("16");
        l16.setHorizontalTextPosition(javax.swing.SwingConstants.CENTER);
        l16.setOpaque(true);
        l16.addMouseListener(new java.awt.event.MouseAdapter() {
            public void mouseEntered(java.awt.event.MouseEvent evt) {
                l16MouseEntered(evt);
            }
            public void mouseExited(java.awt.event.MouseEvent evt) {
                l16MouseExited(evt);
            }
        });
        getContentPane().add(l16);
        l16.setBounds(60, 140, 30, 30);

        l15.setBackground(new java.awt.Color(255, 255, 255));
        l15.setForeground(new java.awt.Color(255, 0, 0));
        l15.setHorizontalAlignment(javax.swing.SwingConstants.CENTER);
        l15.setText("15");
        l15.setHorizontalTextPosition(javax.swing.SwingConstants.CENTER);
        l15.setOpaque(true);
        l15.addMouseListener(new java.awt.event.MouseAdapter() {
            public void mouseEntered(java.awt.event.MouseEvent evt) {
                l15MouseEntered(evt);
            }
            public void mouseExited(java.awt.event.MouseEvent evt) {
                l15MouseExited(evt);
            }
        });
        getContentPane().add(l15);
        l15.setBounds(30, 140, 30, 30);

        l22.setBackground(new java.awt.Color(255, 255, 255));
        l22.setForeground(new java.awt.Color(255, 0, 0));
        l22.setHorizontalAlignment(javax.swing.SwingConstants.CENTER);
        l22.setText("22");
        l22.setHorizontalTextPosition(javax.swing.SwingConstants.CENTER);
        l22.setOpaque(true);
        l22.addMouseListener(new java.awt.event.MouseAdapter() {
            public void mouseEntered(java.awt.event.MouseEvent evt) {
                l22MouseEntered(evt);
            }
            public void mouseExited(java.awt.event.MouseEvent evt) {
                l22MouseExited(evt);
            }
        });
        getContentPane().add(l22);
        l22.setBounds(30, 170, 30, 30);

        l23.setBackground(new java.awt.Color(255, 255, 255));
        l23.setHorizontalAlignment(javax.swing.SwingConstants.CENTER);
        l23.setText("23");
        l23.setHorizontalTextPosition(javax.swing.SwingConstants.CENTER);
        l23.setOpaque(true);
        l23.addMouseListener(new java.awt.event.MouseAdapter() {
            public void mouseEntered(java.awt.event.MouseEvent evt) {
                l23MouseEntered(evt);
            }
            public void mouseExited(java.awt.event.MouseEvent evt) {
                l23MouseExited(evt);
            }
        });
        getContentPane().add(l23);
        l23.setBounds(60, 170, 30, 30);

        l24.setBackground(new java.awt.Color(255, 255, 255));
        l24.setHorizontalAlignment(javax.swing.SwingConstants.CENTER);
        l24.setText("24");
        l24.setHorizontalTextPosition(javax.swing.SwingConstants.CENTER);
        l24.setOpaque(true);
        l24.addMouseListener(new java.awt.event.MouseAdapter() {
            public void mouseEntered(java.awt.event.MouseEvent evt) {
                l24MouseEntered(evt);
            }
            public void mouseExited(java.awt.event.MouseEvent evt) {
                l24MouseExited(evt);
            }
        });
        getContentPane().add(l24);
        l24.setBounds(90, 170, 30, 30);

        l25.setBackground(new java.awt.Color(255, 255, 255));
        l25.setHorizontalAlignment(javax.swing.SwingConstants.CENTER);
        l25.setText("25");
        l25.setHorizontalTextPosition(javax.swing.SwingConstants.CENTER);
        l25.setOpaque(true);
        l25.addMouseListener(new java.awt.event.MouseAdapter() {
            public void mouseEntered(java.awt.event.MouseEvent evt) {
                l25MouseEntered(evt);
            }
            public void mouseExited(java.awt.event.MouseEvent evt) {
                l25MouseExited(evt);
            }
        });
        getContentPane().add(l25);
        l25.setBounds(120, 170, 30, 30);

        l26.setBackground(new java.awt.Color(255, 255, 255));
        l26.setHorizontalAlignment(javax.swing.SwingConstants.CENTER);
        l26.setText("26");
        l26.setHorizontalTextPosition(javax.swing.SwingConstants.CENTER);
        l26.setOpaque(true);
        l26.addMouseListener(new java.awt.event.MouseAdapter() {
            public void mouseEntered(java.awt.event.MouseEvent evt) {
                l26MouseEntered(evt);
            }
            public void mouseExited(java.awt.event.MouseEvent evt) {
                l26MouseExited(evt);
            }
        });
        getContentPane().add(l26);
        l26.setBounds(150, 170, 30, 30);

        l27.setBackground(new java.awt.Color(255, 255, 255));
        l27.setHorizontalAlignment(javax.swing.SwingConstants.CENTER);
        l27.setText("27");
        l27.setHorizontalTextPosition(javax.swing.SwingConstants.CENTER);
        l27.setOpaque(true);
        l27.addMouseListener(new java.awt.event.MouseAdapter() {
            public void mouseEntered(java.awt.event.MouseEvent evt) {
                l27MouseEntered(evt);
            }
            public void mouseExited(java.awt.event.MouseEvent evt) {
                l27MouseExited(evt);
            }
        });
        getContentPane().add(l27);
        l27.setBounds(180, 170, 30, 30);

        l28.setBackground(new java.awt.Color(255, 255, 255));
        l28.setHorizontalAlignment(javax.swing.SwingConstants.CENTER);
        l28.setText("28");
        l28.setHorizontalTextPosition(javax.swing.SwingConstants.CENTER);
        l28.setOpaque(true);
        l28.addMouseListener(new java.awt.event.MouseAdapter() {
            public void mouseEntered(java.awt.event.MouseEvent evt) {
                l28MouseEntered(evt);
            }
            public void mouseExited(java.awt.event.MouseEvent evt) {
                l28MouseExited(evt);
            }
        });
        getContentPane().add(l28);
        l28.setBounds(210, 170, 30, 30);

        l29.setBackground(new java.awt.Color(255, 255, 255));
        l29.setForeground(new java.awt.Color(255, 0, 0));
        l29.setHorizontalAlignment(javax.swing.SwingConstants.CENTER);
        l29.setText("29");
        l29.setHorizontalTextPosition(javax.swing.SwingConstants.CENTER);
        l29.setOpaque(true);
        l29.addMouseListener(new java.awt.event.MouseAdapter() {
            public void mouseEntered(java.awt.event.MouseEvent evt) {
                l29MouseEntered(evt);
            }
            public void mouseExited(java.awt.event.MouseEvent evt) {
                l29MouseExited(evt);
            }
        });
        getContentPane().add(l29);
        l29.setBounds(30, 200, 30, 30);

        l30.setBackground(new java.awt.Color(255, 255, 255));
        l30.setHorizontalAlignment(javax.swing.SwingConstants.CENTER);
        l30.setText("30");
        l30.setHorizontalTextPosition(javax.swing.SwingConstants.CENTER);
        l30.setOpaque(true);
        l30.addMouseListener(new java.awt.event.MouseAdapter() {
            public void mouseEntered(java.awt.event.MouseEvent evt) {
                l30MouseEntered(evt);
            }
            public void mouseExited(java.awt.event.MouseEvent evt) {
                l30MouseExited(evt);
            }
        });
        getContentPane().add(l30);
        l30.setBounds(60, 200, 30, 30);

        l31.setBackground(new java.awt.Color(255, 255, 255));
        l31.setHorizontalAlignment(javax.swing.SwingConstants.CENTER);
        l31.setText("31");
        l31.setHorizontalTextPosition(javax.swing.SwingConstants.CENTER);
        l31.setOpaque(true);
        l31.addMouseListener(new java.awt.event.MouseAdapter() {
            public void mouseEntered(java.awt.event.MouseEvent evt) {
                l31MouseEntered(evt);
            }
            public void mouseExited(java.awt.event.MouseEvent evt) {
                l31MouseExited(evt);
            }
        });
        getContentPane().add(l31);
        l31.setBounds(90, 200, 30, 30);

        l32.setBackground(new java.awt.Color(255, 255, 255));
        l32.setHorizontalAlignment(javax.swing.SwingConstants.CENTER);
        l32.setOpaque(true);
        l32.addMouseListener(new java.awt.event.MouseAdapter() {
            public void mouseEntered(java.awt.event.MouseEvent evt) {
                l32MouseEntered(evt);
            }
            public void mouseExited(java.awt.event.MouseEvent evt) {
                l32MouseExited(evt);
            }
        });
        getContentPane().add(l32);
        l32.setBounds(120, 200, 30, 30);

        l33.setBackground(new java.awt.Color(255, 255, 255));
        l33.setHorizontalAlignment(javax.swing.SwingConstants.CENTER);
        l33.setOpaque(true);
        l33.addMouseListener(new java.awt.event.MouseAdapter() {
            public void mouseEntered(java.awt.event.MouseEvent evt) {
                l33MouseEntered(evt);
            }
            public void mouseExited(java.awt.event.MouseEvent evt) {
                l33MouseExited(evt);
            }
        });
        getContentPane().add(l33);
        l33.setBounds(150, 200, 30, 30);

        l34.setBackground(new java.awt.Color(255, 255, 255));
        l34.setHorizontalAlignment(javax.swing.SwingConstants.CENTER);
        l34.setOpaque(true);
        l34.addMouseListener(new java.awt.event.MouseAdapter() {
            public void mouseEntered(java.awt.event.MouseEvent evt) {
                l34MouseEntered(evt);
            }
            public void mouseExited(java.awt.event.MouseEvent evt) {
                l34MouseExited(evt);
            }
        });
        getContentPane().add(l34);
        l34.setBounds(180, 200, 30, 30);

        l35.setBackground(new java.awt.Color(255, 255, 255));
        l35.setHorizontalAlignment(javax.swing.SwingConstants.CENTER);
        l35.setOpaque(true);
        l35.addMouseListener(new java.awt.event.MouseAdapter() {
            public void mouseEntered(java.awt.event.MouseEvent evt) {
                l35MouseEntered(evt);
            }
            public void mouseExited(java.awt.event.MouseEvent evt) {
                l35MouseExited(evt);
            }
        });
        getContentPane().add(l35);
        l35.setBounds(210, 200, 30, 30);

        jLabel37.setFont(new java.awt.Font("Tahoma", 1, 14));
        jLabel37.setForeground(new java.awt.Color(255, 0, 51));
        jLabel37.setHorizontalAlignment(javax.swing.SwingConstants.CENTER);
        jLabel37.setText("D");
        jLabel37.setHorizontalTextPosition(javax.swing.SwingConstants.CENTER);
        getContentPane().add(jLabel37);
        jLabel37.setBounds(30, 50, 30, 20);

        jLabel38.setFont(new java.awt.Font("Tahoma", 1, 14));
        jLabel38.setHorizontalAlignment(javax.swing.SwingConstants.CENTER);
        jLabel38.setText("S");
        jLabel38.setHorizontalTextPosition(javax.swing.SwingConstants.CENTER);
        getContentPane().add(jLabel38);
        jLabel38.setBounds(60, 50, 30, 20);

        jLabel39.setFont(new java.awt.Font("Tahoma", 1, 14));
        jLabel39.setHorizontalAlignment(javax.swing.SwingConstants.CENTER);
        jLabel39.setText("T");
        jLabel39.setHorizontalTextPosition(javax.swing.SwingConstants.CENTER);
        getContentPane().add(jLabel39);
        jLabel39.setBounds(90, 50, 30, 20);

        jLabel40.setFont(new java.awt.Font("Tahoma", 1, 14));
        jLabel40.setHorizontalAlignment(javax.swing.SwingConstants.CENTER);
        jLabel40.setText("Q");
        jLabel40.setHorizontalTextPosition(javax.swing.SwingConstants.CENTER);
        getContentPane().add(jLabel40);
        jLabel40.setBounds(120, 50, 30, 20);

        jLabel41.setFont(new java.awt.Font("Tahoma", 1, 14));
        jLabel41.setHorizontalAlignment(javax.swing.SwingConstants.CENTER);
        jLabel41.setText("Q");
        jLabel41.setHorizontalTextPosition(javax.swing.SwingConstants.CENTER);
        getContentPane().add(jLabel41);
        jLabel41.setBounds(150, 50, 30, 20);

        jLabel42.setFont(new java.awt.Font("Tahoma", 1, 14));
        jLabel42.setHorizontalAlignment(javax.swing.SwingConstants.CENTER);
        jLabel42.setText("S");
        jLabel42.setHorizontalTextPosition(javax.swing.SwingConstants.CENTER);
        getContentPane().add(jLabel42);
        jLabel42.setBounds(180, 50, 30, 20);
        getContentPane().add(jSeparator1);
        jSeparator1.setBounds(30, 40, 210, 10);

        rotulo.setHorizontalAlignment(javax.swing.SwingConstants.CENTER);
        rotulo.setText("Março de 2011");
        getContentPane().add(rotulo);
        rotulo.setBounds(60, 20, 150, 20);

        l36.setBackground(new java.awt.Color(255, 255, 255));
        l36.setForeground(new java.awt.Color(255, 0, 0));
        l36.setHorizontalAlignment(javax.swing.SwingConstants.CENTER);
        l36.setHorizontalTextPosition(javax.swing.SwingConstants.CENTER);
        l36.setOpaque(true);
        l36.addMouseListener(new java.awt.event.MouseAdapter() {
            public void mouseEntered(java.awt.event.MouseEvent evt) {
                l36MouseEntered(evt);
            }
            public void mouseExited(java.awt.event.MouseEvent evt) {
                l36MouseExited(evt);
            }
        });
        getContentPane().add(l36);
        l36.setBounds(30, 230, 30, 30);

        l37.setBackground(new java.awt.Color(255, 255, 255));
        l37.setHorizontalAlignment(javax.swing.SwingConstants.CENTER);
        l37.setHorizontalTextPosition(javax.swing.SwingConstants.CENTER);
        l37.setOpaque(true);
        l37.addMouseListener(new java.awt.event.MouseAdapter() {
            public void mouseEntered(java.awt.event.MouseEvent evt) {
                l37MouseEntered(evt);
            }
            public void mouseExited(java.awt.event.MouseEvent evt) {
                l37MouseExited(evt);
            }
        });
        getContentPane().add(l37);
        l37.setBounds(60, 230, 30, 30);

        avancar.setHorizontalAlignment(javax.swing.SwingConstants.CENTER);
        avancar.setIcon(new javax.swing.ImageIcon(getClass().getResource("/calendario/imagens/avancarAzul.png"))); // NOI18N
        avancar.addMouseListener(new java.awt.event.MouseAdapter() {
            public void mouseClicked(java.awt.event.MouseEvent evt) {
                avancarMouseClicked(evt);
            }
            public void mouseEntered(java.awt.event.MouseEvent evt) {
                avancarMouseEntered(evt);
            }
            public void mouseExited(java.awt.event.MouseEvent evt) {
                avancarMouseExited(evt);
            }
        });
        getContentPane().add(avancar);
        avancar.setBounds(220, 20, 20, 20);

        voltar.setHorizontalAlignment(javax.swing.SwingConstants.CENTER);
        voltar.setIcon(new javax.swing.ImageIcon(getClass().getResource("/calendario/imagens/voltarAzul.png"))); // NOI18N
        voltar.addMouseListener(new java.awt.event.MouseAdapter() {
            public void mouseClicked(java.awt.event.MouseEvent evt) {
                voltarMouseClicked(evt);
            }
            public void mouseEntered(java.awt.event.MouseEvent evt) {
                voltarMouseEntered(evt);
            }
            public void mouseExited(java.awt.event.MouseEvent evt) {
                voltarMouseExited(evt);
            }
        });
        getContentPane().add(voltar);
        voltar.setBounds(30, 20, 20, 20);

        fundoLabel.setBackground(new java.awt.Color(255, 255, 255));
        fundoLabel.setBorder(javax.swing.BorderFactory.createEtchedBorder());
        fundoLabel.setOpaque(true);
        getContentPane().add(fundoLabel);
        fundoLabel.setBounds(20, 70, 230, 200);

        java.awt.Dimension screenSize = java.awt.Toolkit.getDefaultToolkit().getScreenSize();
        setBounds((screenSize.width-286)/2, (screenSize.height-315)/2, 286, 315);
    }// </editor-fold>//GEN-END:initComponents

    private void l3MouseEntered(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_l3MouseEntered

}//GEN-LAST:event_l3MouseEntered

    private void l3MouseExited(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_l3MouseExited

}//GEN-LAST:event_l3MouseExited

    private void l6MouseEntered(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_l6MouseEntered

}//GEN-LAST:event_l6MouseEntered

    private void l6MouseExited(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_l6MouseExited

}//GEN-LAST:event_l6MouseExited

    private void l7MouseEntered(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_l7MouseEntered

}//GEN-LAST:event_l7MouseEntered

    private void l7MouseExited(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_l7MouseExited

}//GEN-LAST:event_l7MouseExited

    private void l8MouseEntered(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_l8MouseEntered

}//GEN-LAST:event_l8MouseEntered

    private void l8MouseExited(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_l8MouseExited

}//GEN-LAST:event_l8MouseExited

    private void l9MouseEntered(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_l9MouseEntered

}//GEN-LAST:event_l9MouseEntered

    private void l9MouseExited(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_l9MouseExited

}//GEN-LAST:event_l9MouseExited

    private void l10MouseEntered(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_l10MouseEntered

}//GEN-LAST:event_l10MouseEntered

    private void l10MouseExited(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_l10MouseExited

}//GEN-LAST:event_l10MouseExited

    private void l11MouseEntered(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_l11MouseEntered

}//GEN-LAST:event_l11MouseEntered

    private void l11MouseExited(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_l11MouseExited

}//GEN-LAST:event_l11MouseExited

    private void l12MouseEntered(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_l12MouseEntered

}//GEN-LAST:event_l12MouseEntered

    private void l12MouseExited(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_l12MouseExited

}//GEN-LAST:event_l12MouseExited

    private void l13MouseEntered(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_l13MouseEntered

}//GEN-LAST:event_l13MouseEntered

    private void l14MouseEntered(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_l14MouseEntered

}//GEN-LAST:event_l14MouseEntered

    private void l14MouseExited(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_l14MouseExited

}//GEN-LAST:event_l14MouseExited

    private void l21MouseEntered(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_l21MouseEntered

}//GEN-LAST:event_l21MouseEntered

    private void l21MouseExited(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_l21MouseExited

}//GEN-LAST:event_l21MouseExited

    private void l20MouseEntered(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_l20MouseEntered

}//GEN-LAST:event_l20MouseEntered

    private void l20MouseExited(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_l20MouseExited

}//GEN-LAST:event_l20MouseExited

    private void l19MouseEntered(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_l19MouseEntered

}//GEN-LAST:event_l19MouseEntered

    private void l19MouseExited(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_l19MouseExited

}//GEN-LAST:event_l19MouseExited

    private void l18MouseEntered(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_l18MouseEntered

}//GEN-LAST:event_l18MouseEntered

    private void l18MouseExited(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_l18MouseExited

}//GEN-LAST:event_l18MouseExited

    private void l17MouseEntered(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_l17MouseEntered

}//GEN-LAST:event_l17MouseEntered

    private void l17MouseExited(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_l17MouseExited

}//GEN-LAST:event_l17MouseExited

    private void l16MouseEntered(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_l16MouseEntered

}//GEN-LAST:event_l16MouseEntered

    private void l16MouseExited(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_l16MouseExited

}//GEN-LAST:event_l16MouseExited

    private void l15MouseEntered(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_l15MouseEntered

}//GEN-LAST:event_l15MouseEntered

    private void l15MouseExited(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_l15MouseExited

}//GEN-LAST:event_l15MouseExited

    private void l22MouseEntered(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_l22MouseEntered

}//GEN-LAST:event_l22MouseEntered

    private void l22MouseExited(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_l22MouseExited

}//GEN-LAST:event_l22MouseExited

    private void l23MouseEntered(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_l23MouseEntered

}//GEN-LAST:event_l23MouseEntered

    private void l23MouseExited(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_l23MouseExited

}//GEN-LAST:event_l23MouseExited

    private void l24MouseEntered(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_l24MouseEntered

}//GEN-LAST:event_l24MouseEntered

    private void l24MouseExited(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_l24MouseExited

}//GEN-LAST:event_l24MouseExited

    private void l25MouseEntered(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_l25MouseEntered

}//GEN-LAST:event_l25MouseEntered

    private void l25MouseExited(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_l25MouseExited

}//GEN-LAST:event_l25MouseExited

    private void l26MouseEntered(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_l26MouseEntered

}//GEN-LAST:event_l26MouseEntered

    private void l26MouseExited(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_l26MouseExited

}//GEN-LAST:event_l26MouseExited

    private void l27MouseEntered(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_l27MouseEntered

}//GEN-LAST:event_l27MouseEntered

    private void l27MouseExited(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_l27MouseExited

}//GEN-LAST:event_l27MouseExited

    private void l28MouseEntered(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_l28MouseEntered

}//GEN-LAST:event_l28MouseEntered

    private void l28MouseExited(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_l28MouseExited

}//GEN-LAST:event_l28MouseExited

    private void l29MouseEntered(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_l29MouseEntered

}//GEN-LAST:event_l29MouseEntered

    private void l29MouseExited(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_l29MouseExited

}//GEN-LAST:event_l29MouseExited

    private void l30MouseEntered(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_l30MouseEntered

}//GEN-LAST:event_l30MouseEntered

    private void l30MouseExited(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_l30MouseExited

}//GEN-LAST:event_l30MouseExited

    private void l31MouseEntered(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_l31MouseEntered

}//GEN-LAST:event_l31MouseEntered

    private void l31MouseExited(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_l31MouseExited
     
}//GEN-LAST:event_l31MouseExited

    private void l13MouseExited(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_l13MouseExited

    }//GEN-LAST:event_l13MouseExited

    private void l32MouseEntered(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_l32MouseEntered

    }//GEN-LAST:event_l32MouseEntered

    private void l34MouseEntered(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_l34MouseEntered

    }//GEN-LAST:event_l34MouseEntered

    private void l34MouseExited(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_l34MouseExited

    }//GEN-LAST:event_l34MouseExited

    private void l35MouseEntered(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_l35MouseEntered

    }//GEN-LAST:event_l35MouseEntered

    private void l35MouseExited(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_l35MouseExited

    }//GEN-LAST:event_l35MouseExited

    private void l36MouseEntered(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_l36MouseEntered

    }//GEN-LAST:event_l36MouseEntered

    private void l36MouseExited(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_l36MouseExited

    }//GEN-LAST:event_l36MouseExited

    private void l37MouseEntered(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_l37MouseEntered

    }//GEN-LAST:event_l37MouseEntered

    private void l37MouseExited(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_l37MouseExited

    }//GEN-LAST:event_l37MouseExited

    private void l32MouseExited(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_l32MouseExited

    }//GEN-LAST:event_l32MouseExited

    private void l33MouseEntered(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_l33MouseEntered

    }//GEN-LAST:event_l33MouseEntered

    private void l33MouseExited(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_l33MouseExited

    }//GEN-LAST:event_l33MouseExited

    private void avancarMouseEntered(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_avancarMouseEntered
    avancar.setIcon(new javax.swing.ImageIcon(getClass().getResource("/calendario/imagens/avancarVerde.png")));
    }//GEN-LAST:event_avancarMouseEntered

    private void avancarMouseExited(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_avancarMouseExited
    avancar.setIcon(new javax.swing.ImageIcon(getClass().getResource("/calendario/imagens/avancarAzul.png")));
    }//GEN-LAST:event_avancarMouseExited

    private void avancarMouseClicked(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_avancarMouseClicked
    proximaGrade();
    }//GEN-LAST:event_avancarMouseClicked

    private void voltarMouseEntered(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_voltarMouseEntered
    voltar.setIcon(new javax.swing.ImageIcon(getClass().getResource("/calendario/imagens/voltarVerde.png")));
    }//GEN-LAST:event_voltarMouseEntered

    private void voltarMouseExited(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_voltarMouseExited
    voltar.setIcon(new javax.swing.ImageIcon(getClass().getResource("/calendario/imagens/voltarAzul.png")));
    }//GEN-LAST:event_voltarMouseExited

    private void voltarMouseClicked(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_voltarMouseClicked
    anteriorGrade();
    }//GEN-LAST:event_voltarMouseClicked

    /**
    * @param args the command line arguments
    */
    public static void main(String args[]) {
        java.awt.EventQueue.invokeLater(new Runnable() {
            public void run() {
                InterFaceCalendario dialog = new InterFaceCalendario(new javax.swing.JFrame(), true);
                dialog.addWindowListener(new java.awt.event.WindowAdapter() {
                    public void windowClosing(java.awt.event.WindowEvent e) {
                        System.exit(0);
                    }
                });
                dialog.setVisible(true);
            }
        });
    }

    // Variables declaration - do not modify//GEN-BEGIN:variables
    private javax.swing.JLabel avancar;
    private javax.swing.JLabel fundoLabel;
    private javax.swing.JLabel jLabel1;
    private javax.swing.JLabel jLabel37;
    private javax.swing.JLabel jLabel38;
    private javax.swing.JLabel jLabel39;
    private javax.swing.JLabel jLabel40;
    private javax.swing.JLabel jLabel41;
    private javax.swing.JLabel jLabel42;
    private javax.swing.JSeparator jSeparator1;
    private javax.swing.JLabel l1;
    private javax.swing.JLabel l10;
    private javax.swing.JLabel l11;
    private javax.swing.JLabel l12;
    private javax.swing.JLabel l13;
    private javax.swing.JLabel l14;
    private javax.swing.JLabel l15;
    private javax.swing.JLabel l16;
    private javax.swing.JLabel l17;
    private javax.swing.JLabel l18;
    private javax.swing.JLabel l19;
    private javax.swing.JLabel l2;
    private javax.swing.JLabel l20;
    private javax.swing.JLabel l21;
    private javax.swing.JLabel l22;
    private javax.swing.JLabel l23;
    private javax.swing.JLabel l24;
    private javax.swing.JLabel l25;
    private javax.swing.JLabel l26;
    private javax.swing.JLabel l27;
    private javax.swing.JLabel l28;
    private javax.swing.JLabel l29;
    private javax.swing.JLabel l3;
    private javax.swing.JLabel l30;
    private javax.swing.JLabel l31;
    private javax.swing.JLabel l32;
    private javax.swing.JLabel l33;
    private javax.swing.JLabel l34;
    private javax.swing.JLabel l35;
    private javax.swing.JLabel l36;
    private javax.swing.JLabel l37;
    private javax.swing.JLabel l4;
    private javax.swing.JLabel l5;
    private javax.swing.JLabel l6;
    private javax.swing.JLabel l7;
    private javax.swing.JLabel l8;
    private javax.swing.JLabel l9;
    private javax.swing.JLabel rotulo;
    private javax.swing.JLabel voltar;
    // End of variables declaration//GEN-END:variables

}